<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>来访接待智能PPT生成器</title>
    <link href="https://cdn.bootcdn.net/ajax/libs/bootstrap/5.3.0/css/bootstrap.min.css" rel="stylesheet">
    <link href="https://cdn.bootcdn.net/ajax/libs/font-awesome/6.4.0/css/all.min.css" rel="stylesheet">
    <link href="static/css/style.css" rel="stylesheet">
</head>
<body>
    <nav class="navbar navbar-dark bg-primary">
        <div class="container">
            <span class="navbar-brand mb-0 h1">
                <i class="fas fa-magic me-2"></i>来访接待智能PPT生成器
            </span>
        </div>
    </nav>

    <div class="container mt-5">
        <div class="row justify-content-center">
            <div class="col-lg-8">
                <div class="card shadow">
                    <div class="card-header bg-light">
                        <h5 class="mb-0">生成定制化接待PPT</h5>
                    </div>
                    <div class="card-body">
                        <form id="pptForm">
                            <div class="mb-3">
                                <label class="form-label">来访对象类型</label>
                                <select class="form-select" id="visitorType" required>
                                    <option value="">请选择来访对象类型</option>
                                    <option value="leader">公司领导</option>
                                    <option value="guest">外部客人</option>
                                </select>
                            </div>

                            <div class="mb-3">
                                <label class="form-label">来访人姓名</label>
                                <input type="text" class="form-control" id="visitorName" placeholder="请输入来访人姓名" required>
                            </div>

                            <div class="mb-3">
                                <label class="form-label">职务</label>
                                <input type="text" class="form-control" id="visitorPosition" placeholder="请输入职务" required>
                            </div>

                            <div class="mb-3">
                                <label class="form-label">来访目的</label>
                                <select class="form-select" id="visitPurpose" required>
                                    <option value="">请选择来访目的</option>
                                    <option value="inspection">工作视察</option>
                                    <option value="meeting">商务洽谈</option>
                                    <option value="exchange">技术交流</option>
                                    <option value="cooperation">合作签约</option>
                                </select>
                            </div>

                            <div class="mb-3">
                                <label class="form-label">预计时长（分钟）</label>
                                <input type="number" class="form-control" id="duration" min="15" max="180" value="60" required>
                            </div>

                            <div class="mb-3">
                                <label class="form-label">公司简介重点</label>
                                <select class="form-select" id="companyFocus" required>
                                    <option value="">请选择介绍重点</option>
                                    <option value="overview">公司概况</option>
                                    <option value="achievement">业绩展示</option>
                                    <option value="technology">技术实力</option>
                                    <option value="development">发展规划</option>
                                </select>
                            </div>

                            <div class="d-grid">
                                <button type="submit" class="btn btn-primary" id="generateBtn">
                                    <i class="fas fa-magic me-2"></i>生成PPT
                                </button>
                            </div>
                        </form>
                    </div>
                </div>

                <!-- 预览区域 -->
                <div id="previewArea" class="mt-4" style="display: none;">
                    <div class="card shadow">
                        <div class="card-header bg-success text-white">
                            <h5 class="mb-0">
                                <i class="fas fa-eye me-2"></i>PPT预览
                            </h5>
                        </div>
                        <div class="card-body">
                            <div id="pptPreview" class="text-center">
                                <p class="text-muted">正在生成PPT...</p>
                            </div>
                            <div class="mt-3 text-center">
                                <a id="downloadLink" href="#" class="btn btn-success me-2" download>
                                    <i class="fas fa-download me-2"></i>下载PPTX
                                </a>
                                <button type="button" class="btn btn-secondary" onclick="resetForm()">
                                    <i class="fas fa-redo me-2"></i>重新生成
                                </button>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <script src="https://cdn.bootcdn.net/ajax/libs/bootstrap/5.3.0/js/bootstrap.bundle.min.js"></script>
    <script src="static/js/app.js"></script>
</body>
</html>
